#ifndef AED_PARTICLESYSTEMCOMP_H
#define AED_PARTICLESYSTEMCOMP_H

#include <QString>
#include <QTextStream>
#include <QDomDocument>

using namespace std;


class AED_ParticleSystemComp
{
    QString m_particle;

    int m_totalparticles;
    int m_lifetime;

    int m_particle_lifetime;
    float m_particle_velocity;
    float m_particle_size;
    int m_randomness;
    bool m_fading;
    bool m_animate;
    float m_scaling;
    bool m_rotate_particles;
    float m_velocity_interpolation;

    bool m_autostart;

    bool m_autokill;
    bool m_loop;

    int m_interval;
    bool m_enabled;

public:
    AED_ParticleSystemComp();
    AED_ParticleSystemComp& operator =(const AED_ParticleSystemComp &comp);

    bool IsEnabled(){return m_enabled;}
    void SetEnabled(bool enabled){m_enabled=enabled;}

    QString GetParticle(){return m_particle;}
    void SetParticle(const QString &particle){m_particle = particle;}

    int GetTotalParticles(){return m_totalparticles;}
    void SetTotalParticles(int particles){m_totalparticles = particles;}

    int GetLifeTime(){return m_lifetime;}
    void SetLifeTime(int lifetime){m_lifetime=lifetime;}

    int GetParticleLifeTime(){return m_particle_lifetime;}
    void SetParticleLifeTime(int lifetime){m_particle_lifetime=lifetime;}

    float GetParticleVelocity(){return m_particle_velocity;}
    void SetParticleVelocity(float vel){m_particle_velocity=vel;}

    float GetParticleSize(){return m_particle_size;}
    void SetParticleSize(float size){m_particle_size=size;}

    int GetRandomness(){return m_randomness;}
    void SetRandomness(int randomness){m_randomness=randomness;}

    bool GetFading(){return m_fading;}
    void SetFading(bool fading){m_fading=fading;}

    bool GetAnimate(){return m_animate;}
    void SetAnimate(bool animate){m_animate=animate;}

    float GetScaling(){return m_scaling;}
    void SetScaling(float scaling){m_scaling=scaling;}

    bool GetParticleRotation(){return m_rotate_particles;}
    void SetParticleRotation(bool rotate){m_rotate_particles=rotate;}

    float GetVelocityInterpolation(){return m_velocity_interpolation;}
    void SetVelocityInterpolation(float vel){m_velocity_interpolation=vel;}

    bool GetAutoStart(){return m_autostart;}
    void SetAutoStart(bool autostart){m_autostart=autostart;}

    bool GetAutoKill(){return m_autokill;}
    void SetAutoKill(bool autokill){m_autokill=autokill;}

    bool GetLoop(){return m_loop;}
    void SetLoop(bool loop){m_loop=loop;}

    int GetInterval(){return m_interval;}
    void SetInterval(int interval){m_interval=interval;}

    void Save(QTextStream &file);
    void Save(QDomDocument &doc, QDomElement &pelem);

    void Load(QDomElement &celem);
};

#endif // AED_PARTICLESYSTEMCOMP_H
